#ifndef CAMPAIGN_H
#define CAMPAIGN_H


#include "dtwenty_global.h"
#include "dtwentyitem.h"
#include "skill.h"
#include "specialability.h"
#include "characterclass.h"


#include <QVariantMap>


class DTWENTYSHARED_EXPORT Campaign : public DTwentyItem
{
    Q_OBJECT

//    class Data : public QSharedData
//    {
//    public:
//        Data() {}
//        Data(const Data& other) : QSharedData(other)
//        {

//        }



//    };

public:

    Q_INVOKABLE Campaign(const QString& name = QString(), QObject* parent = 0);
    Campaign(const Campaign& other);

    virtual int fieldCount() const;

    void initialize();

    bool changed() const;


public slots:

    void onChanged(bool changed = true);


private:

    SkillContainer* skillsContainer();
    SpecialAbilityContainer* specialsContainer();
    CharacterClassContainer* classContainer();

    bool m_changed;

//    QExplicitlySharedDataPointer<Data> d;


};

Q_DECLARE_METATYPE(Campaign)

#endif // CAMPAIGN_H
